<?php

class Wee_Logging_Block_Adminhtml_Grid_Filter_User extends Mage_Adminhtml_Block_Widget_Grid_Column_Filter_Select
{
    public function _getOptions()
    {
        $options = array(array('value' => '', 'label' => Mage::helper('wee_logging')->__('All Users')));
        foreach(Mage::getResourceModel('wee_logging/event')->getUserNames() as $username) {
            $options[] = array('value' => $username, 'label' => $username);
        }
        return $options;
    }

    public function getCondition()
    {
        return $this->getValue();
    }
}
